# -*- coding: utf-8 -*-
from common.helper import Helper
from db.mysql import MysqlClient
class Arrangement( object ):

    def __init__(self):
        self.mysql = MysqlClient()
        self.name = "平安i无忧医疗保险"

        # 拉取数据

    def pullData(self, data={}):
        for item in Helper.selectData(self.name, self.mysql):
            data["name"] = self.name
            data["company"] = "平安保险"
            data["year"] = item["year"]
            data["socialSec"] =  item["socialSec"]
            data["expire"] = item["expire"]
            data["payType"] = item["payType"]
            data["cancerMedical"] = str(int(int(item["cancerMedical"])/10000)) + "w"
            data["deductible"] = item["deductible"] + "w"
            data["price"] = item["price"]
            Helper.mergeTable( self.name,self.mysql,data )
